package com.controller;

import io.swagger.annotations.Api;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.multipart.MultipartFile;

/**
 * @author HuangSuip
 */

@RequestMapping("/file")
@Controller
@Transactional
@Api("file")
public class FileController {


    @PostMapping(value = "/upload")
    @ResponseBody
    public String getView(MultipartFile file) {
        System.out.println(file.getName());

        return "user";
    }
}
